package com.mingqijia.gassafety.authority.api.req.config;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotNull;
import javax.validation.constraints.Pattern;
import java.io.Serializable;

/**
 * 更新字典项请求参数
 * @author Damon S.
 * @version v0.2
 * @description 更新字典项请求参数
 * @date 2021-04-23 19:55
 */
@Data
@ApiModel("更新字典项请求参数")
public class UpdateDictionaryItemReqDTO implements Serializable {

    @NotNull(message = "字典项ID不能为空")
    @ApiModelProperty(value = "字典项ID", required = true)
    private String id;

    @NotNull(message = "字典项名称不能为空")
    @ApiModelProperty(value = "字典名称", required = true)
    @Pattern(regexp = "\\S{1,50}$", message = "名称应满足1-50位汉字、字母、数字、符号")
    private String name;

    @NotNull(message = "字典类型值不能为空")
    @ApiModelProperty(value = "字典类型取值")
    private String value;

    @ApiModelProperty(value = "排序值")
    private Integer ordinal;

    @ApiModelProperty(value = "描述信息")
    private String description;

    private String dictCode;

    private String companyName;

}
